package com.example.mybatisplusdemo.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.example.mybatisplusdemo.model.domain.Review;
import com.baomidou.mybatisplus.extension.service.IService;
import com.example.mybatisplusdemo.model.dto.ReviewDTO;

import java.util.List;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author lxp
 * @since 2025-07-04
 */
public interface IReviewService extends IService<Review> {

    Page<ReviewDTO> listReviewsByUserId(Page<ReviewDTO> page, Long userId);

    List<ReviewDTO> getReviewByStoreId(Long storeId);

    List<ReviewDTO> getChildReviewByParentId(Long parentId);

    List<Long> listChildIdByParentId(Long parentId);

    boolean insertParentReview(ReviewDTO reviewDTO);

    boolean insertChildReview(ReviewDTO reviewDTO);


    List<Review> getParentReviewsByUserId(Long userId);
}
